package com.usv.reader.impl;

import com.usv.reader.ImageReader;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import javax.imageio.ImageIO;

public class ImageFileReader implements ImageReader {

    File file;

    public ImageFileReader(File file) {
        this.file = file;
    }

    public BufferedImage readImage() {
        BufferedImage bufImg = null;
        try {
            bufImg = ImageIO.read(file);
        } catch (IOException e) {
            e.printStackTrace();
        }
        return bufImg;
    }
}
